home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 13704 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  734 b 

  1. Path: dragon.solect.com!usenet
  2. From: John Moore <john@affinityedge.com>
  3. Newsgroups: comp.lang.c++
  4. Subject: Problem with append.
  5. Date: Mon, 25 Mar 1996 10:42:58 -0500
  6. Organization: AffinityEdge.com
  7. Message-ID: <3156BF02.33A1@affinityedge.com>
  8. NNTP-Posting-Host: blackburn.affinityedge.com
  9. Mime-Version: 1.0
  10. Content-Type: text/plain; charset=us-ascii
  11. Content-Transfer-Encoding: 7bit
  12. X-Mailer: Mozilla 2.0 (X11; I; SunOS 5.4 sun4m)
  13.  
  14. I've been having a problem with appending to a file. 
  15.  
  16.  
  17. out.open(filename, ios::app, 0);
  18.  
  19. if (!out) {
  20.   cout << "Cannot open ERROR log file.\n";
  21.   return(FALSE);
  22.   }
  23.  
  24.  
  25. out.close();
  26.  
  27. This code works the first time, but if the file exists then the 
  28. routine hangs indefinitely. 
  29.  
  30. Any Ideas ?
  31.  
  32. Thanks
  33.     John.
  34.